﻿@model IEnumerable<Testicide.Models.Project>


@{
    ViewBag.Title = "Search";
}
  <div class="order">
        <h4>Search Result</h4>

        <div style="font-weight:600; font-size:larger;">@ViewBag.Message</div>
        <br />
        @if(Model.Count()!=0)
        {
            <table class="table table-hover">
                <tr>
                    <th>
                        @Html.DisplayNameFor(model => model.Name)
                    </th>
                    <th>
                        @Html.DisplayNameFor(model => model.Url)
                    </th>
                    <th>
                        @Html.DisplayNameFor(model => model.Date)
                    </th>
                    <th>
                    
                    </th>
                </tr>

                @foreach (var item in Model)
                {
                    <tr>
                        <td>
                            <a href="@Url.Action("Details","Project", new { id=item.ID })">
                                @Html.DisplayFor(modelItem => item.Name)
                            </a>
                        </td>
                        <td>
                            @Html.DisplayFor(modelItem => item.Url)
                        </td>
                        <td>
                            @Html.DisplayFor(modelItem => item.Date)
                        </td>
                        <td>
                            <a href="@Url.Action("Edit","Project", new { id=item.ID })">
                                <img class="icons" src="~/pictures/edit.png" />
                            </a>|

                            <a href="@Url.Action("Delete","Project", new { id=item.ID })">
                                <img class="icons" src="~/pictures/delete.png" />
                            </a>
                        </td>
                    </tr>
                }


            </table>
        }
        <br />
        @Html.ActionLink("Back to all Projects","Index")
    </div>
